﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<hercules.Models.Venda>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Index
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<h2>Index</h2>

<p>
    <%: Html.ActionLink("Create New", "Create") %>
</p>
<table id="ver-zebra">
    <colgroup>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
        <col class="vzebra-even"/>
        <col class="vzebra-odd"/>
    </colgroup>
    <thead>
    <tr>
        <th scope="col" id="vzebra-comedy">
            Pessoa1
        </th>
        <th scope="col" id="vzebra-action">
            Pessoa
        </th>
        <th scope="col" id="vzebra-comedy">
            modelo
        </th>
        <th scope="col" id="vzebra-action">
            dataEmissao
        </th>
        <th scope="col" id="vzebra-comedy">
            dataSaida
        </th>
        <th scope="col" id="vzebra-action">
            naturezaCFOP
        </th>
        <th scope="col" id="vzebra-comedy">
            valorTotal
        </th>
        <th scope="col" id="vzebra-action">
            desconto
        </th>
        <th scope="col" id="vzebra-comedy">
            quantidade
        </th>
        <th scope="col" id="vzebra-action">
            valorUnitario
        </th>
        <th scope="col" id="vzebra-comedy">
            valorTotalProduto
        </th>
        <th scope="col" id="vzebra-action">
            statusVenda
        </th>
        <th scope="col" id="vzebra-comedy"></th>
    </tr>
    </thead>
    <tbody>
<% foreach (var item in Model) { %>
    <tr>
        <td>
            <%: Html.DisplayFor(modelItem => item.Pessoa1.cpf) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.Pessoa.cpf) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.modelo) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.dataEmissao) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.dataSaida) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.naturezaCFOP) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.valorTotal) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.desconto) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.quantidade) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.valorUnitario) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.valorTotalProduto) %>
        </td>
        <td>
            <%: Html.DisplayFor(modelItem => item.statusVenda) %>
        </td>
        <td>
            <%: Html.ActionLink("Edit", "Edit", new { id=item.numeroNota }) %> |
            <%: Html.ActionLink("Details", "Details", new { id=item.numeroNota }) %> |
            <%: Html.ActionLink("Delete", "Delete", new { id=item.numeroNota }) %>
        </td>
    </tr>
<% } %>
</tbody>
</table>

</asp:Content>
